package com.bosssoft.hr.train.jsp.example.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.RequiredArgsConstructor;


/**
 * @description: 用户实体类 判断对象相等重写 equals 和 hashcode 很重要哦
 *           加上@Data 注解不再需要编写
 * @author: ChenTong
 * @create: 2020-05-29 14:52
 * @since
 **/
@Data
@AllArgsConstructor
@RequiredArgsConstructor
public class User {
    private Long id;
    private String name;

    private String code;
    private String password;

    public User(Long id, String name) {
        this.id = id;
        this.name = name;
    }
    public User(String code, String password) {
        this.code = code;
        this.password = password;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }
}
